package com.example.demo.system.service.impl;

import com.alibaba.csp.sentinel.annotation.SentinelResource;
import com.example.demo.system.entity.User;
import com.example.demo.system.feign.UserClient;
import com.example.demo.system.mapper.UserMapper;
import com.example.demo.system.service.IUserService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author wangys
 * @since 2025-05-19
 */
@Service
public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements IUserService {
    
    @Resource
    UserMapper userMapper;
    @Resource
    UserClient userClient;
    @Override
    public List<User> getUser() {
        return userMapper.selectList(null);
    }
    public String callHello(String name) {
        return userClient.hello(name);
    }

}
